﻿using Nemerle.Collections;
using Nemerle.Text;
using Nemerle.Utility;

using System;
using System.Collections.Generic;
using System.Linq;

using ROList = System.Collections.ObjectModel.ReadOnlyCollection;

namespace Nemerle2.Compiler
{
  /// <summary>
  /// Описывает сборку или проект на который имеется ссылка из другого проекта.
  /// http://code.google.com/p/nemerle-2/wiki/IReferencedAssembly
  /// </summary>
  public interface IReferencedAssembly
  {
    CustomAttributes  : ICustomAttributes { get; }
    TopLevelTypes     : Seq[ITypeInfo]    { get; }
    AllTypes          : Seq[ITypeInfo]    { get; }
    Macros            : Seq[IMacroInfo]      { get; }
    Msgs              : list[Msg]         { get; }
    ImagePath         : string            { get; }
    FullName          : string            { get; }
    Name              : string            { get; }
    ///Specifies a bitwise combination of AssemblyNameFlags flags for an assembly,
    ///describing just-in-time (JIT) compiler options, whether the assembly is retargetable,
    ///and whether it has a full or tokenized public key. This class cannot be inherited.
    Flags             : AssemblyNameFlags { get; }

    event Changed : EventHandler;
    
    ///Loads all types of assembly
    Init() : void;
    
    LookupType(name : string, typeParamsCount : int) : ITypeInfo;
    Namespaces : ReadOnlyArray[string * ReadOnlyArray[ITypeInfo] * ReadOnlyArray[IMacroInfo]] { get; }
  }
}
